package bookshelf;
import java.util.Set;

public interface BookShelf {

	/**
	 * Adds a book to the book shelf and assigns it to the passed author.
	 * @param book the book to add
	 * @param author the author of the book
	 */
	public void addBook(Book book, Author author);
	
	/**
	 * Gets all the books contained in the book shelf.
	 * Returns an empty set when there are not book registered.
	 * @return the set of books contained in the book shelf
	 */
	public Set<Book> getBooks();
	
	/**
	 * Gets the all the different authors of the books contained in the book shelf.
	 * Returns an empty set if there are no authors registered.
	 * @return the set of registered authors.
	 */
	public Set<Author> getAuthors();
	
	/**
	 * Gets all the books associated with the passed author. 
	 * If the author does not exist an empty set is returned.
	 * @param author the author whose books are obtained
	 * @return the set of books written by the passed author
	 */
	public Set<Book> getBooks(Author author);
}
